// pages/login/index.js
Page({
  data: {
    countDownVisible: false,
    time: 10
  },
  getSMSCode() {
    this.setData({
      countDownVisible: true
    })
  },
  change(ev) {
    this.setData({
      time: ev.detail
    })
    if (ev.detail === 0) {
      this.setData({
        countDownVisible: false
      })
    }
  }
})